//
//  BodiView.m
//  UI03
//
//  Created by Bodi on 16/6/7.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "BodiView.h"
#import "BodiUILabel.h"
#import "BodiTextField.h"

@implementation BodiView

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/
//-(instancetype)initWithFrame:(CGRect)frame text:(NSString *)text{
//    
//    self = [super initWithFrame:frame];
//    if (self) {
//        = text;
//    }
//    
//    return self;
//}


-(instancetype)initWithFrame:(CGRect)frame withText:(NSString *)text iniFrame:(CGRect)frameLable{
    self = [super initWithFrame:frame];
    if (self) {
//        self.leftLable = _leftLable;
//        self.rightTextField = _rightTextField;
        
        self.leftLable.text = text;
        self.leftLable.frame = frameLable;
        self.leftLable.backgroundColor =[UIColor blueColor];
        BodiUILabel *left = [[BodiUILabel alloc]initWithFrame:CGRectMake(10, 10, 100, 40) text:@"用户名"];
        BodiTextField *right = [[BodiTextField alloc] initWithFrame:CGRectMake(150, 10, 100, 40) placeholder:@"输入密码"];
        
        [self addSubview:left];
        [self addSubview:right];
        
        
        
        
    }

    return self;

}













//-(instancetype)initWithFrame:(CGRect)frame {
//    self = [super initWithFrame:frame];
//    
//    
//    return self;
//
//
//
//}
//+(instancetype)viewWithFrame:(CGRect)frame{
//
//    BodiView *view = [[BodiView alloc]init];
//    view addSubview:
//
//}

@end
